<!--
*Author：jxx
 *Contact：283591387@qq.com
 *代码由框架生成,任何更改都可能导致被代码生成器覆盖
 *业务请在@/extension/system/workbusiness/EQU_MOVE_PATH.js此处编写
 -->
<template>
    <view-grid ref="grid"
               :columns="columns"
               :detail="detail"
               :editFormFields="editFormFields"
               :editFormOptions="editFormOptions"
               :searchFormFields="searchFormFields"
               :searchFormOptions="searchFormOptions"
               :table="table"
               :extend="extend">
    </view-grid>
</template>
<script>
    import extend from "@/extension/system/workbusiness/EQU_MOVE_PATH.js";
    import { ref, defineComponent } from "vue";
    export default defineComponent({
        setup() {
            const table = ref({
                key: 'MovePath_Id',
                footer: "Foots",
                cnName: '运动路径',
                name: 'workbusiness/EQU_MOVE_PATH',
                url: "/EQU_MOVE_PATH/",
                sortName: "CreateOn"
            });
            const editFormFields = ref({"Identifier":"","MovePathZH":"","WorkCenterId":"","MaxPathNo":"","MinPathNo":"","PathType":""});
            const editFormOptions = ref([[{"title":"编码","field":"Identifier","type":"text"},
                               {"title":"名称","field":"MovePathZH","type":"text"},
                               {"dataKey":"工作中心","data":[],"title":"工作中心","field":"WorkCenterId","type":"select"},
                               {"title":"路径序号Max","field":"MaxPathNo","type":"number"},
                               {"title":"路径序号Min","field":"MinPathNo","type":"number"},
                               {"dataKey":"路径类型","data":[],"title":"路径类型","field":"PathType","type":"select"}]]);
            const searchFormFields = ref({});
            const searchFormOptions = ref([]);
            const columns = ref([{field:'MovePath_Id',title:'MovePath_Id',type:'guid',width:110,hidden:true,readonly:true,require:true,align:'left'},
                       {field:'Identifier',title:'编码',type:'string',width:110,align:'left',sort:true},
                       {field:'MovePathZH',link:true, title:'名称',type:'string',width:110,align:'left'},
                       {field:'WorkCenterId',title:'工作中心',type:'string',bind:{ key:'工作中心',data:[]},width:110,align:'left'},
                       {field:'MaxPathNo',title:'路径序号Max',type:'int',width:110,align:'left'},
                       {field:'MinPathNo',title:'路径序号Min',type:'int',width:110,align:'left'},
                       {field:'PathType',title:'路径类型',type:'string',bind:{ key:'路径类型',data:[]},width:110,align:'left'},
                       {field:'Description',title:'描述',type:'string',width:110,align:'left'},
                       {field:'Status',title:'状态',type:'string',width:110,hidden:true,align:'left'},
                       {field:'CreateBy',title:'创建人',type:'string',width:110,hidden:true,align:'left'},
                       {field:'CreateOn',title:'创建时间',type:'datetime',width:150,hidden:true,align:'left',sort:true},
                       {field:'UpdateBy',title:'更新人',type:'string',width:110,hidden:true,align:'left'},
                       {field:'LastUpdateOn',title:'更新时间',type:'datetime',width:150,hidden:true,align:'left',sort:true},
                       {field:'IsDeleted',title:'逻辑删除 0/不删除 1/已删除',type:'bool',width:110,hidden:true,align:'left'}]);
            const detail = ref({
                cnName: "运动路径明细",
                table: "EQU_MOVE_PATH_SUB",
                columns: [{field:'Id',title:'Id',type:'guid',width:110,hidden:true,readonly:true,require:true,align:'left'},
                       {field:'MovePath_Id',title:'MovePath_Id',type:'guid',width:110,hidden:true,align:'left'},
                       {field:'SubPathNo',title:'路径序号',type:'int',width:110,edit:{type:'number'},align:'left',sort:true},
                       {field:'EquEquipmentId',title:'设备',type:'string',bind:{ key:'设备',data:[]},width:110,edit:{type:'select'},align:'left'},
                       {field:'EquOrder',title:'设备排序',type:'int',width:110,edit:{type:'number'},align:'left'},
                       {field:'Description',title:'描述',type:'string',width:110,edit:{type:'text'},align:'left'},
                       {field:'Status',title:'状态',type:'string',width:110,hidden:true,align:'left'},
                       {field:'CreateBy',title:'创建人',type:'string',width:110,hidden:true,align:'left'},
                       {field:'CreateOn',title:'创建时间',type:'datetime',width:150,hidden:true,align:'left',sort:true},
                       {field:'UpdateBy',title:'更新人',type:'string',width:110,hidden:true,align:'left'},
                       {field:'LastUpdateOn',title:'更新时间',type:'datetime',width:150,hidden:true,align:'left',sort:true},
                       {field:'IsDeleted',title:'逻辑删除 0/不删除 1/已删除',type:'bool',width:110,hidden:true,align:'left'}],
                sortName: "EquOrder",
                key: "Id"
            });
            return {
                table,
                extend,
                editFormFields,
                editFormOptions,
                searchFormFields,
                searchFormOptions,
                columns,
                detail,
            };
        },
    });
</script>
